﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace UBCon.Navigation.Models
{
    [Serializable]
    internal class OutlookBarSettings
    {
        #region Private fields

        private int _itemsCount, _actualItemsCount, _maxVisibleItemsCount, _hVisibleItems, _vVisibleItems, _selectedIndex;

        private bool _isMinimized, _isCompact, _animationsEnabled;

        double _paneWidth, _expandWidth;

        List<int> _hashCodes = new List<int>();

        List<int> indexes = new List<int>();

        #endregion

        #region Public properties

        /// <summary>
        /// Gets or sets overall items count.
        /// </summary>
        public int ItemsCount 
        {
            get 
            {
                return _itemsCount;
            }
            set 
            {
                _itemsCount = value;
            }
        }

        /// <summary>
        /// Gets or sets size of PaneWidth.
        /// </summary>
        public double PaneWidth 
        {
            get 
            {
                return _paneWidth;
            }
            set 
            {
                _paneWidth = value;
            }
        }

        /// <summary>
        /// Gets or sets a boolean value indicating whether control is minimized or not.
        /// </summary>
        public bool IsMinimized 
        {
            get 
            {
                return _isMinimized;
            }
            set 
            {
                _isMinimized = value;
            }
        }

        /// <summary>
        /// Gets or sets maximum visible items count.
        /// </summary>
        public int MaxVisibleItemsCount 
        {
            get 
            {
                return _maxVisibleItemsCount;
            }
            set 
            {
                _maxVisibleItemsCount = value;
            }
        }

        /// <summary>
        /// Gets or sets actual items count.
        /// </summary>
        public int ActualItemsCount 
        {
            get 
            {
                return _actualItemsCount;
            }
            set 
            {
                _actualItemsCount = value;
            }
        }
        //_hVisibleItems, _vVisibleItems;

        /// <summary>
        /// Gets or sets visible items count when control is not in minimized state.
        /// </summary>
        public int hVisibleItems 
        {
            get 
            {
                return _hVisibleItems;
            }
            set 
            {
                _hVisibleItems = value;
            }
        }

        /// <summary>
        /// Gets or sets visible items count when control is in minimized state.
        /// </summary>
        public int vVisibleItems 
        {
            get 
            {
                return _vVisibleItems;
            }
            set 
            {
                _vVisibleItems = value;
            }
        }

        /// <summary>
        /// Gets or sets collection of contols' hash codes.
        /// </summary>
        public List<int> HashCodes 
        {
            get 
            {
                return _hashCodes;
            }
            set 
            {
                _hashCodes = value;
            }
        }

        /// <summary>
        /// Gets or sets collection of control's model.
        /// </summary>
        internal List<int> Indexes 
        {
            get 
            {
                return indexes;
            }
            set 
            {
                indexes = value;
            }
        }

        /// <summary>
        /// Gets or sets a boolean value indicating whether control is compact or not.
        /// </summary>
        public bool IsCompact 
        {
            get 
            {
                return _isCompact;
            }
            set 
            {
                _isCompact = value;
            }
        }

        /// <summary>
        /// Gets or sets SelectedIndex.
        /// </summary>
        public int SelectedIndex 
        {
            get 
            {
                return _selectedIndex;
            }
            set 
            {
                _selectedIndex = value;
            }
        }

        /// <summary>
        /// Gets or sets a boolean value which indicates whether OutlookBar control can use advanced animations.
        /// Note: Before enabling advanced animations hardware's RenderCapability.Tier property is also considered.
        public bool AnimationsEnabled 
        {
            get 
            {
                return _animationsEnabled;
            }
            set 
            {
                _animationsEnabled = value;
            } 
        }

        /// <summary>
        /// Gets or sets last modified width of OutlookBar before it's minimized.
        /// </summary>
        public double ExpandWidth 
        {
            get 
            {
                return _expandWidth;
            }
            set 
            {
                _expandWidth = value;
            }
        }
        #endregion

    }
}
